600
I am using Layout property to sort multiple columns at once. The problem is that all items get expanded. How do I prevent that

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"P1")));
	var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column->PutPartialCheck(VARIANT_TRUE);
EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"P2")));
	var_Column1->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column1->PutPartialCheck(VARIANT_TRUE);
	var_Column1->PutFormatColumn(L"1 index ``");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child A");
	var_Items->InsertItem(h,vtMissing,"Child B");
	var_Items->InsertItem(h,vtMissing,"Child A");
	var_Items->InsertItem(h,vtMissing,"Child B");
	var_Items->AddItem("Root");
	var_Items->AddItem("Root");
spTree1->PutSingleSort(VARIANT_FALSE);
spTree1->PutLayout(L"multiplesort=\"C0:1 C1:2\";collapse=\"\"");
spTree1->EndUpdate();

599
How can I get ride / hide the image being dragged by OLE Drag and Drop
// OLEStartDrag event - Occurs when the OLEDrag method is called.
void OnOLEStartDragTree1(LPDISPATCH   Data,long FAR*   AllowedEffects)
{
	// Data.SetData("data to drag")
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	AllowedEffects = 1;
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutOLEDropMode(EXTREELib::exOLEDropManual);
spTree1->PutBackground(EXTREELib::exDragDropAfter,RGB(255,255,255));
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->GetColumns()->Add(L"Default");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);

598
How can I export checked items only

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"C1")))->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"C2")))->PutFormatColumn(L"1 index `A-Z`");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"C3")))->PutFormatColumn(L"100 index ``");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->PutCellState(var_Items->AddItem("Item 2"),long(0),1);
	var_Items->PutCellState(var_Items->AddItem("Item 3"),long(0),1);
spTree1->EndUpdate();
OutputDebugStringW( L"Export CSV Checked Items Only:" );
OutputDebugStringW( _bstr_t(spTree1->Export("","chk")) );

597
How can I export a hidden column

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"C1");
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"C2")));
		var_Column->PutFormatColumn(L"1 index `A-Z`");
		var_Column->PutVisible(VARIANT_FALSE);
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"C3")));
		var_Column1->PutFormatColumn(L"100 index ``");
		var_Column1->PutVisible(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
spTree1->EndUpdate();
OutputDebugStringW( L"Export CSV Hidden Columns (1,2):" );
OutputDebugStringW( _bstr_t(spTree1->Export("","|1,2")) );

596
I'm trying to use automatic numbering of the outline. How can I have A, B, C for root items, 1, 2, 3 for the sub-items, and a, b, c for sub-sub-items (sample 3)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutDrawGridLines(EXTREELib::exRowLines);
spTree1->PutAutoDrag(EXTREELib::exAutoDragPositionAny);
spTree1->PutHasLines(EXTREELib::exSolidLine);
spTree1->PutIndent(16);
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"")));
		var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
		var_Column->PutFormatColumn(L"((1:=(0 :=(1 rpos '.|A-Z||a-z|')) rfind `.`) < 0 ? `<b>` + =:0 + `` :  (=:0 mid (1 + 1 + =:1) )  + `)` ) + ` ` + value");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child");
	long hChild = var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->PutExpandItem(0,VARIANT_TRUE);
	h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child");
	hChild = var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->PutCellState(hChild,long(0),1);
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(h,vtMissing,"Child");
spTree1->EndUpdate();

595
I'm trying to use automatic numbering of the outline. How can I have A, B, C for root items, 1, 2, 3 for the sub-items, and a, b, c for sub-sub-items (sample 2)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutGridLineColor(RGB(190,190,190));
spTree1->PutDrawGridLines(EXTREELib::exRowLines);
spTree1->PutAutoDrag(EXTREELib::exAutoDragPositionAny);
spTree1->PutHasLines(EXTREELib::exSolidLine);
spTree1->PutIndent(16);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Default");
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"")));
		var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
		var_Column->PutDef(EXTREELib::exCellPaddingRight,long(4));
		var_Column->PutAllowSizing(VARIANT_FALSE);
		var_Column->PutWidth(36);
		var_Column->PutPosition(0);
		var_Column->PutFormatColumn(_bstr_t("(1:=(0 :=(1 rpos '.|A-Z||a-z|')) rfind `.`) < 0 ? `<b>` + =:0 : (`............` left 2 * (=:0 count `.`)) + (=:0 mid (1 + 1 + =") +
":1) ) ");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child");
	long hChild = var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->PutExpandItem(0,VARIANT_TRUE);
	h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child");
	hChild = var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->PutCellState(hChild,long(0),1);
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(h,vtMissing,"Child");
spTree1->EndUpdate();

594
I'm trying to use automatic numbering of the outline. How can I have A, B, C for root items, 1, 2, 3 for the sub-items, and a, b, c for sub-sub-items (sample 1)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutDrawGridLines(EXTREELib::exRowLines);
spTree1->PutAutoDrag(EXTREELib::exAutoDragPositionAny);
spTree1->PutHasLines(EXTREELib::exSolidLine);
spTree1->PutIndent(16);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Default");
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"")));
		var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
		var_Column->PutDef(EXTREELib::exCellPaddingRight,long(4));
		var_Column->PutAlignment(EXTREELib::RightAlignment);
		var_Column->PutAllowSizing(VARIANT_FALSE);
		var_Column->PutWidth(24);
		var_Column->PutPosition(0);
		var_Column->PutFormatColumn(L"(1:=(0 :=(1 rpos '.|A-Z||a-z|')) rfind `.`) < 0 ? `<b>` + =:0 : `<i>` + (=:0 mid (1 + 1 + =:1) ) ");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child");
	long hChild = var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->PutExpandItem(0,VARIANT_TRUE);
	h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child");
	hChild = var_Items->InsertItem(h,vtMissing,"Child");
	var_Items->PutCellState(hChild,long(0),1);
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(hChild,vtMissing,"Child");
	var_Items->InsertItem(h,vtMissing,"Child");
spTree1->EndUpdate();

593
Is it possible to have a different alignment for parts of the cell's caption

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutTreeColumnIndex(-1);
spTree1->PutDrawGridLines(EXTREELib::exRowLines);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Default")));
	var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellHAlignment(var_Items->AddItem("all-left"),long(0),EXTREELib::LeftAlignment);
	var_Items->PutCellHAlignment(var_Items->AddItem("all-center"),long(0),EXTREELib::CenterAlignment);
	var_Items->PutCellHAlignment(var_Items->AddItem("all-right"),long(0),EXTREELib::RightAlignment);
	long h = var_Items->AddItem("left<c>center<r>right");
	var_Items->PutCellCaptionFormat(h,long(0),EXTREELib::exHTML);
spTree1->EndUpdate();

592
I have a column with Def(exCellSingleLine) property on False, word-wrapping, and I am wondering if possible to update the column's content while user is resizing it
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"MultipleLine")));
		var_Column->PutWidth(32);
		var_Column->PutDef(EXTREELib::exCellSingleLine,VARIANT_FALSE);
		var_Column->PutDef(EXTREELib::exColumnResizeContiguously,VARIANT_TRUE);
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"SingleLine")));
		var_Column1->PutDef(EXTREELib::exCellSingleLine,VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem("This is a bit of long text that should break the line"),long(1),"This is a bit of long text that should break the line");
spTree1->EndUpdate();

591
How do I sort the index column as numeric

// AddItem event - Occurs after a new Item has been inserted to Items collection.
void OnAddItemTree1(long   Item)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		var_Items->PutCellData(Item,long(1),var_Items->GetItemToIndex(Item));
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutDrawGridLines(EXTREELib::exAllLines);
spTree1->PutColumnAutoResize(VARIANT_TRUE);
spTree1->PutShowFocusRect(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Next")));
	var_Column->PutDef(EXTREELib::exCellPaddingLeft,long(4));
	var_Column->PutDef(EXTREELib::exHeaderPaddingLeft,long(4));
EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Index")));
	var_Column1->PutAllowSizing(VARIANT_FALSE);
	var_Column1->PutWidth(48);
	var_Column1->PutFormatColumn(L"(((0 := (1 index ``)) mod 3) case ( default: ``; 0 : `<r><fgcolor=B0B0B0>`; 1: ``; 2 : `<c><fgcolor=808080>` )) + str(=:0)");
	var_Column1->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	var_Column1->PutSortType(EXTREELib::SortUserData);
	var_Column1->PutPosition(0);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
	var_Items->AddItem("Item 4");
	var_Items->AddItem("Item 5");
	var_Items->AddItem("Item 6");
	var_Items->AddItem("Item 7");
	var_Items->AddItem("Item 8");
	var_Items->AddItem("Item 9");
	var_Items->AddItem("Item 10");
spTree1->EndUpdate();

590
How can I put icons/images into buttons

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_TRUE);
spTree1->Images(_bstr_t("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq") +
"lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" +
"0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" +
"NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=");
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"C+B")));
	var_Column->PutAllowSizing(VARIANT_FALSE);
	var_Column->PutWidth(48);
	var_Column->PutFormatColumn(L"` <img>` + ( 1 + (1 index ``) mod 3 ) + `</img> `");
	var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column->PutDef(EXTREELib::exCellHasButton,VARIANT_TRUE);
	var_Column->PutDef(EXTREELib::exCellButtonAutoWidth,VARIANT_TRUE);
spTree1->GetColumns()->Add(L"");
spTree1->PutDrawGridLines(EXTREELib::exVLines);
spTree1->PutDefaultItemHeight(20);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
spTree1->EndUpdate();

589
Is it possible to have a CheckBox and Button TOGETHER on all cells in a column

// CellButtonClick event - Fired after the user clicks on the cell of button type. 
void OnCellButtonClickTree1(long   Item,long   ColIndex)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	OutputDebugStringW( L"CellButtonClick" );
	OutputDebugStringW( L"Item" );
}

// CellStateChanged event - Fired after cell's state has been changed.
void OnCellStateChangedTree1(long   Item,long   ColIndex)
{
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	OutputDebugStringW( L"CellStateChanged" );
	OutputDebugStringW( L"Item" );
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_TRUE);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"")));
	var_Column->PutAllowSizing(VARIANT_FALSE);
	var_Column->PutWidth(32);
	var_Column->PutFormatColumn(L"1 index ``");
EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")));
	var_Column1->PutAllowSizing(VARIANT_FALSE);
	var_Column1->PutWidth(48);
	var_Column1->PutFormatColumn(L"`     `");
	var_Column1->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column1->PutDef(EXTREELib::exCellHasButton,VARIANT_TRUE);
	var_Column1->PutDef(EXTREELib::exCellButtonAutoWidth,VARIANT_TRUE);
spTree1->GetColumns()->Add(L"");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
	var_Items->AddItem("");
spTree1->EndUpdate();

588
Does filtering work with umlauts / accents characters
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Names")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutFilterType(EXTREELib::exPattern);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Mantel");
	var_Items->AddItem("Mechanik");
	var_Items->AddItem("Motor");
	var_Items->AddItem("Murks");
	var_Items->AddItem("Märchen");
	var_Items->AddItem("Möhren");
	var_Items->AddItem("Mühle");
	var_Items->AddItem("Sérigraphie");
spTree1->GetColumns()->GetItem(long(0))->PutFilter(L"*ä*");
spTree1->ApplyFilter();
spTree1->EndUpdate();

587
The Items.FirstVisibleItem property is read-only. How can I change the first visible item

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos")));
	var_Column->PutPosition(0);
	var_Column->PutFormatColumn(L"0 index ``");
	var_Column->PutWidth(32);
	var_Column->PutDef(EXTREELib::exCellBackColor,long(15790320));
spTree1->PutScrollPos(VARIANT_TRUE,13);
spTree1->EndUpdate();

586
How FullPath method works

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->GetColumns()->Add(L"C1");
spTree1->GetColumns()->Add(L"C2");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->PutCellCaption(h,long(1),"A");
	var_Items->PutCellCaption(var_Items->InsertItem(h,vtMissing,"Child 1"),long(1),"B");
	var_Items->PutCellCaption(var_Items->InsertItem(h,vtMissing,"Child 2"),long(1),"C");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
spTree1->PutSearchColumnIndex(1);
OutputDebugStringW( _bstr_t(spTree1->GetSearchColumnIndex()) );
OutputDebugStringW( ->GetFullPath(spTree1->GetItems()->GetItemByIndex(2)) );
spTree1->PutSearchColumnIndex(0);
OutputDebugStringW( _bstr_t(spTree1->GetSearchColumnIndex()) );
OutputDebugStringW( ->GetFullPath(spTree1->GetItems()->GetItemByIndex(2)) );
spTree1->EndUpdate();

585
How can I filter for multiple captions on a single column, using OR clause

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_TRUE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
spTree1->PutMarkSearchColumn(VARIANT_TRUE);
spTree1->PutSearchColumnIndex(1);
spTree1->PutFilterBarPromptVisible(VARIANT_TRUE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Name")))->PutWidth(96);
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Title")));
		var_Column->PutWidth(96);
	var_Columns->Add(L"City");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h0 = var_Items->AddItem("Nancy Davolio");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Seattle");
	h0 = var_Items->AddItem("Andrew Fuller");
	var_Items->PutCellCaption(h0,long(1),"Vice President, Sales");
	var_Items->PutCellCaption(h0,long(2),"Tacoma");
	var_Items->PutSelectItem(h0,VARIANT_TRUE);
	h0 = var_Items->AddItem("Janet Leverling");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Kirkland");
	h0 = var_Items->AddItem("Margaret Peacock");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Redmond");
	h0 = var_Items->AddItem("Steven Buchanan");
	var_Items->PutCellCaption(h0,long(1),"Sales Manager");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Michael Suyama");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Robert King");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Laura Callahan");
	var_Items->PutCellCaption(h0,long(1),"Inside Sales Coordinator");
	var_Items->PutCellCaption(h0,long(2),"Seattle");
	h0 = var_Items->AddItem("Anne Dodsworth");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
spTree1->PutFilterBarPromptColumns("1");
spTree1->PutFilterBarPromptPattern(L"Vice Inside");
spTree1->PutFilterBarPromptType(EXTREELib::exFilterPromptContainsAny);
spTree1->EndUpdate();

584
How can I filter for multiple captions on a single column, using AND clause

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_TRUE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
spTree1->PutMarkSearchColumn(VARIANT_TRUE);
spTree1->PutSearchColumnIndex(1);
spTree1->PutFilterBarPromptVisible(VARIANT_TRUE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Name")))->PutWidth(96);
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Title")));
		var_Column->PutWidth(96);
	var_Columns->Add(L"City");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h0 = var_Items->AddItem("Nancy Davolio");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Seattle");
	h0 = var_Items->AddItem("Andrew Fuller");
	var_Items->PutCellCaption(h0,long(1),"Vice President, Sales");
	var_Items->PutCellCaption(h0,long(2),"Tacoma");
	var_Items->PutSelectItem(h0,VARIANT_TRUE);
	h0 = var_Items->AddItem("Janet Leverling");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Kirkland");
	h0 = var_Items->AddItem("Margaret Peacock");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Redmond");
	h0 = var_Items->AddItem("Steven Buchanan");
	var_Items->PutCellCaption(h0,long(1),"Sales Manager");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Michael Suyama");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Robert King");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Laura Callahan");
	var_Items->PutCellCaption(h0,long(1),"Inside Sales Coordinator");
	var_Items->PutCellCaption(h0,long(2),"Seattle");
	h0 = var_Items->AddItem("Anne Dodsworth");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
spTree1->PutFilterBarPromptColumns("1");
spTree1->PutFilterBarPromptPattern(L"Vice Sales");
spTree1->PutFilterBarPromptType(EXTREELib::exFilterPromptContainsAll);
spTree1->EndUpdate();

583
Can I set the search box / filterbarprompt to invisible, so I can use my own input and *string* via VBA
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_TRUE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutSearchColumnIndex(1);
spTree1->PutFilterBarHeight(0);
spTree1->PutFilterBarPromptVisible(VARIANT_TRUE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Name")))->PutWidth(96);
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Title")))->PutWidth(96);
	var_Columns->Add(L"City");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h0 = var_Items->AddItem("Nancy Davolio");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Seattle");
	h0 = var_Items->AddItem("Andrew Fuller");
	var_Items->PutCellCaption(h0,long(1),"Vice President, Sales");
	var_Items->PutCellCaption(h0,long(2),"Tacoma");
	var_Items->PutSelectItem(h0,VARIANT_TRUE);
	h0 = var_Items->AddItem("Janet Leverling");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Kirkland");
	h0 = var_Items->AddItem("Margaret Peacock");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"Redmond");
	h0 = var_Items->AddItem("Steven Buchanan");
	var_Items->PutCellCaption(h0,long(1),"Sales Manager");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Michael Suyama");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Robert King");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
	h0 = var_Items->AddItem("Laura Callahan");
	var_Items->PutCellCaption(h0,long(1),"Inside Sales Coordinator");
	var_Items->PutCellCaption(h0,long(2),"Seattle");
	h0 = var_Items->AddItem("Anne Dodsworth");
	var_Items->PutCellCaption(h0,long(1),"Sales Representative");
	var_Items->PutCellCaption(h0,long(2),"London");
spTree1->PutFilterBarPromptPattern(L"London");
spTree1->EndUpdate();

582
How to load a hierarchy using the control's DataSource property (Parent-ID-Relation)

// AddItem event - Occurs after a new Item has been inserted to Items collection.
void OnAddItemTree1(long   Item)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		var_Items->SetParent(Item,var_Items->GetFindItem(var_Items->GetCellCaption(Item,"ReportsTo"),"EmployeeID",vtMissing));
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("SELECT * FROM Employees ORDER BY ReportsTo","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->GetItems()->PutExpandItem(0,VARIANT_TRUE);
spTree1->EndUpdate();

581
Is there any option to control where I can drop the items when using the AutoDrag property
// AllowAutoDrag event - Occurs when the user drags the item between InsertA and InsertB as child of NewParent.
void OnAllowAutoDragTree1(long   Item,long   NewParent,long   InsertA,long   InsertB,BOOL FAR*   Cancel)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		OutputDebugStringW( L"NewParent" );
		OutputDebugStringW( _bstr_t(var_Items->GetCellCaption(NewParent,long(0))) );
		OutputDebugStringW( L"After" );
		OutputDebugStringW( _bstr_t(var_Items->GetCellCaption(InsertA,long(0))) );
		OutputDebugStringW( L"Before" );
		OutputDebugStringW( _bstr_t(var_Items->GetCellCaption(InsertB,long(0))) );
	Cancel = VARIANT_TRUE;
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutAutoDrag(EXTREELib::exAutoDragPositionAny);
spTree1->PutLinesAtRoot(EXTREELib::exNoLinesAtRoot);
spTree1->PutHasLines(EXTREELib::exThinLine);
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->GetColumns()->Add(L"Task");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Group 1");
	var_Items->PutItemDivider(h,0);
	var_Items->PutItemBold(h,VARIANT_TRUE);
	long h1 = var_Items->InsertItem(h,vtMissing,"Task 1");
	long h2 = var_Items->InsertItem(h,vtMissing,"Task 2");
	long h3 = var_Items->InsertItem(h,vtMissing,"Task 3");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("Group 2");
	var_Items->PutItemBold(h,VARIANT_TRUE);
	var_Items->PutItemDivider(h,0);
spTree1->EndUpdate();

580
The FindPath is not case sensitive. How can I make it work case sensitive

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->GetColumns()->Add(L"Default");
spTree1->PutASCIIUpper(L"");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("L:");
	var_Items->InsertItem(h,vtMissing,"test");
	var_Items->InsertItem(h,vtMissing,"Test");
	var_Items->InsertItem(h,vtMissing,"TEST");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	var_Items->PutItemBold(var_Items->GetFindPath(L"L:\\TEST"),VARIANT_TRUE);
spTree1->EndUpdate();

579
How do I enable / display a tooltip while user selects new items from the drop down filter panel

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Items")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowExclude | EXTREELib::exEnableToolTip | EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
	var_Items->AddItem("Item 4");
EXTREELib::IColumnPtr var_Column1 = spTree1->GetColumns()->GetItem(long(0));
	var_Column1->PutFilterType(EXTREELib::FilterTypeEnum(EXTREELib::exFilterExclude | EXTREELib::exFilter));
	var_Column1->PutFilter(L"Item 1|Item 4");
spTree1->ApplyFilter();
spTree1->EndUpdate();

578
How can I align captions of items with checkbox, with items with no checkbox

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetColumns()->Add(L"Default");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellImages(var_Items->AddItem(long(0)),long(0),"1");
	var_Items->PutCellHasCheckBox(var_Items->AddItem(long(1)),long(0),VARIANT_TRUE);
	var_Items->PutCellImages(var_Items->AddItem(long(2)),long(0),"1");
spTree1->EndUpdate();

577
The control does not ensure the item to fit the control's client area once the user clicks the cell's button or check box. What can be done
// MouseDown event - Occurs when the user presses a mouse button.
void OnMouseDownTree1(short   Button,short   Shift,long   X,long   Y)
{
	// Items.EnsureVisibleItem(ItemFromPoint(-1,-1,c,hit))
}

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutTreeColumnIndex(-1);
spTree1->PutSelForeColor(spTree1->GetForeColor());
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Buttons")));
	var_Column->PutAlignment(EXTREELib::CenterAlignment);
	var_Column->PutDef(EXTREELib::exCellHasButton,VARIANT_TRUE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Button A");
	var_Items->AddItem("Button B");
	var_Items->AddItem("Button C");
spTree1->EndUpdate();

576
Does the title of the cell's tooltip supports HTML format

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"")));
	var_Column->PutCaption(L"");
	var_Column->PutHTMLCaption(L"Column");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellToolTip(var_Items->AddItem("tooltip w/h different title"),long(0),_bstr_t("<c><b><fgcolor=FF0000>Title</fgcolor></b><br>This is bit of text that's shown when the user hovers the cell. This shows the tit") +
"le centered with a different color.");
spTree1->EndUpdate();

575
How do I specify a different title for the cell's tooltip

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"")));
	var_Column->PutCaption(L"This is the title");
	var_Column->PutHTMLCaption(L"Column");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellToolTip(var_Items->AddItem("tooltip w/h different title"),long(0),L"This is bit of text that's shown when the user hovers the cell.");
spTree1->EndUpdate();

574
The cell's tooltip displays the column's caption in its title. How can I get ride of that

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"C1");
	var_Columns->Add(L"C2");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("tooltip w/h caption");
	var_Items->PutCellToolTip(h,long(0),L"This is bit of text that's shown when the user hovers the cell. This shows the column's caption in the title.");
	var_Items->PutCellCaption(h,long(1),"tooltip no caption");
	var_Items->PutCellToolTip(h,long(1),L"This is bit of text that's shown when the user hovers the cell. This shows no column's caption in the title.");
EXTREELib::IColumnPtr var_Column = spTree1->GetColumns()->GetItem("C2");
	var_Column->PutHTMLCaption(var_Column->GetCaption());
	var_Column->PutCaption(L"");
spTree1->EndUpdate();

573
How can I programmatically show the column's filter

// RClick event - Fired when right mouse button is clicked
void OnRClickTree1()
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	long i = spTree1->GetItemFromPoint(-1,-1,c,hit);
	spTree1->GetColumns()->GetItem(c)->ShowFilter("-1,-1,128,128");
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutShowFocusRect(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Items ")));
	var_Column->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowExclude | EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
spTree1->EndUpdate();

572
I want to be able to click on one of the headers, and sort by other column. How can I do that (method 2)

// ColumnClick event - Fired after the user clicks on column's header.
void OnColumnClickTree1(LPDISPATCH   Column)
{
	// Column.SortOrder = 1
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	spTree1->PutSortOnClick(EXTREELib::exDefaultSort);
	spTree1->GetColumns()->GetItem("Sort")->PutSortOrder(EXTREELib::SortAscending);
	spTree1->PutSortOnClick(EXTREELib::exUserSort);
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutSortOnClick(EXTREELib::exUserSort);
spTree1->GetColumns()->Add(L"Items");
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Sort")))->PutVisible(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem("Item 1 (3)"),long(1),long(3));
	var_Items->PutCellCaption(var_Items->AddItem("Item 2 (1)"),long(1),long(1));
	var_Items->PutCellCaption(var_Items->AddItem("Item 3 (2)"),long(1),long(2));
spTree1->EndUpdate();

571
I want to be able to click on one of the headers, and sort by other column. How can I do that (method 1)

// ColumnClick event - Fired after the user clicks on column's header.
void OnColumnClickTree1(LPDISPATCH   Column)
{
	// Column.SortOrder = 1
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	spTree1->GetItems()->SortChildren(0,"Sort",VARIANT_TRUE);
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutSortOnClick(EXTREELib::exUserSort);
spTree1->GetColumns()->Add(L"Items");
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Sort")))->PutVisible(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem("Item 1 (3)"),long(1),long(3));
	var_Items->PutCellCaption(var_Items->AddItem("Item 2 (1)"),long(1),long(1));
	var_Items->PutCellCaption(var_Items->AddItem("Item 3 (2)"),long(1),long(2));
spTree1->EndUpdate();

570
I have a 3 level hierarchy in the treeview, and I want to create a filter that only shows the items in the 2nd level of the hierarchy, is this possible

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->GetColumns()->Add(L"Items");
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Level")))->PutVisible(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Parent");
	var_Items->PutCellCaption(h,long(1),long(0));
	long hChild = var_Items->InsertItem(h,vtMissing,"Child 1.1");
	var_Items->PutCellCaption(hChild,long(1),long(1));
	long hSubChild = var_Items->InsertItem(hChild,vtMissing,"SubChild A");
	var_Items->PutCellCaption(hSubChild,long(1),long(2));
	hChild = var_Items->InsertItem(h,vtMissing,"Child 1.2");
	var_Items->PutCellCaption(hChild,long(1),long(1));
	hSubChild = var_Items->InsertItem(hChild,vtMissing,"SubChild B");
	var_Items->PutCellCaption(hSubChild,long(1),long(2));
	var_Items->PutExpandItem(h,VARIANT_TRUE);
spTree1->PutFilterInclude(EXTREELib::exMatchingItemsOnly);
EXTREELib::IColumnPtr var_Column = spTree1->GetColumns()->GetItem("Level");
	var_Column->PutFilterType(EXTREELib::exFilter);
	var_Column->PutFilter(L"2");
spTree1->ApplyFilter();

569
How can I sort by two-columns, one by date and one by time

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutSingleSort(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Index")))->PutFormatColumn(L"1 index ``");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Date")))->PutSortType(EXTREELib::SortDate);
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Time")));
		var_Column->PutSortType(EXTREELib::SortTime);
		var_Column->PutFormatColumn(L"time(value)");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(long(0));
	var_Items->PutCellCaption(h,long(1),COleDateTime(2001,1,1,0,00,00).operator DATE());
	var_Items->PutCellCaption(h,long(2),COleDateTime(2001,1,1,10,00,00).operator DATE());
	h = var_Items->AddItem(long(0));
	var_Items->PutCellCaption(h,long(1),COleDateTime(2000,12,31,0,00,00).operator DATE());
	var_Items->PutCellCaption(h,long(2),COleDateTime(2001,1,1,10,00,00).operator DATE());
	h = var_Items->AddItem(long(0));
	var_Items->PutCellCaption(h,long(1),COleDateTime(2001,1,1,0,00,00).operator DATE());
	var_Items->PutCellCaption(h,long(2),COleDateTime(2001,1,1,6,00,00).operator DATE());
	h = var_Items->AddItem(long(0));
	var_Items->PutCellCaption(h,long(1),COleDateTime(2000,12,31,0,00,00).operator DATE());
	var_Items->PutCellCaption(h,long(2),COleDateTime(2001,1,1,8,00,00).operator DATE());
	h = var_Items->AddItem(long(0));
	var_Items->PutCellCaption(h,long(1),COleDateTime(2001,1,1,0,00,00).operator DATE());
	var_Items->PutCellCaption(h,long(2),COleDateTime(2001,1,1,8,00,00).operator DATE());
	h = var_Items->AddItem(long(0));
	var_Items->PutCellCaption(h,long(1),COleDateTime(2000,12,31,0,00,00).operator DATE());
	var_Items->PutCellCaption(h,long(2),COleDateTime(2001,1,1,6,00,00).operator DATE());
spTree1->PutLayout(L"multiplesort=\"C1:1 C2:1\"");
spTree1->EndUpdate();

568
We are using custom buttons for the +/- on the treeview control, is there a way to control the size of the image

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IAppearancePtr var_Appearance = spTree1->GetVisualAppearance();
	var_Appearance->Add(3,_bstr_t("gBFLBCJwBAEHhEJAAChABDEMACAADACAxRDQNABQKAAzQFAYbBkGqGAAGIYxYgmFgAQhFcZQSKUOQTDKMIziaQIRg8JYlDTJcIjKKEVQHFiXIrAKKwEgmEQMQiCcbzX") +
"IUBxAAqVZZFUaKAi+Qg4TLBAzUSAAYhtHqeJBjID4JA6UJXRpIAIQSSBUjGOg6TiMUYZAguAxCEzZUT0fAYUQSCC3ZzDCKoRpiCT7Xg8V5OVbjUz9P7AMBwLA7erxap6" +
"PJeD54QymGp/R5eMhyLI8UxXFqRY6veKtJhGDIrT5CEIQVA9EyXJqnahqOiaCguPorQy/dYYdg2BYBPS6MAvG4bVrOd59XrgN42fY2ByzAqlMQwS7rOqiY6YWTnehWTo" +
"HE+JZUmoLB5CufQuAkBYkGO+ZrDWAo7keZZyHmH5+i8X4bluaJyHgGB9mQHx3JjBpViqJRHmueZ7H8Xo3i2fYAl+d5tncMRfDcdZeDMDIjCCJwokoEoQiEJ4KCIfIdgU" +
"SZIAWaoGCEUh2BIJ4gnKBgMDICAnHoCggg0Aw4k0KAJkIagaguYwIj4LAmiKEw2CUIIiHMUJSDQSYyGCFYMGQCJCD0JRjiMRg3gmTYjGSVgmgkchSD4JJklIRIXCSSQY" +
"j4U4UgkQhGE+EwJEkJJWhGpgGGIOBNmMdhPg8SRiHCGAlibNhohqJpJi4T4ZA2WYIgEYInGOGJlDkCQyECDoTEkKQ+E+C5oCIVhQCUCQpnSDoeg4SZZH8YdhjibQ7AiU" +
"gkgcJFyiyEYmGmOhqhyJ5pmILoYCKaRSB6Eg7CcZgZggaRqHqNoTiuDpKkKMormsQ4xiUYgYiKEo6CCWgWiqPovloZoGjoKQYiQBCAg==");
	var_Appearance->Add(4,_bstr_t("gBFLBCJwBAEHhEJAAChABDcMACAADACAxRDQNABQKAAzQFAYbBkGqGAAGIYxYgmFgAQhFcZQSKUOQTDKMIziaQIRg8JYlDTJcIjKKEVQHFiXIrAKKwEgmEQMQiCcbzX") +
"IUBxAAqVZZFUaKAi+Qg4TLBAzUSAAYhtHqeJBjID4JA6UJXRpIAIQSSBUjGOg6TiMUYZAguAxCEzZUT0fAYUQSCC3ZzDCKoRpiCT7Xg8V5OVbjUz9P7AMBwLA7erxap6" +
"PJeD54QymGp/R5eMhyLI8UxXFqRY6veKtJhGDIrT5CEIQVA9EyXJqnahqOiaCguPorQy/dYYdg2BYBPS6MAvG4bVrOd59XrgN42fY2ByzAqlMQwS7rOqiY6YWTnehWTo" +
"HE+JZUmoLB5CufQuAkBYkGO+ZrDWAo7keZZyHmPQ+g8X4fluYBhneEB9l0Iwpg6RRWiqFQfg+V5nnefh/GAB5yAIfRMFeRZdHeDJDCiSApkoMoEiQKBJmKCIfCcYQiHI" +
"FYFkmeBaBOA5JmgMIhgITICAmXoBkgIxAk4MxKAIcIaD+YpIjYLoLmMCI2CkJoiGMNgiCCIhDFCUg0EmMhghWDBkAkBg9CUY4jEYN4JA2IxklYJoJHIUg+CSZJSESFwk" +
"mUKRSFOFRlCIUIRhOZJCFISQ1iQdgEgGGJOBMeJdhOY5SFiHAmAkaYmG6GwmhmLhthsJJ5hSXYYkgFgKHgOYOFOEITCQCJpDSEoTmgQhUhOIRoHoGoCh+SJpnCZIeBed" +
"gaHgO4OlOMINCISByECDQikkGhuh2JwpmqBogCKaYiC6FwhmkQ4yHgYYYgaFopiuaRakCbIsisSpGjYOwaFYIYKCkK5CA2IRqiwCwFiYaBrkKEYKEAQCAgA==");
	var_Appearance->Add(1,"CP:3 -4 -4 4 4");
	var_Appearance->Add(2,"CP:4 -4 -4 4 4");
spTree1->PutDefaultItemHeight(22);
spTree1->PutLinesAtRoot(EXTREELib::exGroupLinesAtRoot);
spTree1->PutHasButtons(EXTREELib::exCustom);
spTree1->PutHasButtonsCustom(VARIANT_FALSE,16777216);
spTree1->PutHasButtonsCustom(VARIANT_TRUE,33554432);
spTree1->GetColumns()->Add(L"Column");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root 1");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("Root 2");
	var_Items->InsertItem(h,vtMissing,"Child");
spTree1->EndUpdate();

567
How can I connect to a DBF file
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADODB.Recordset");
	rs->Open("Select * From foxcode.DBF","Provider=vfpoledb;Data Source=C:\\Program Files\\Microsoft Visual FoxPro 9\\",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->EndUpdate();

566
Do you have any Fit-To-Page options when printing the control

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->EndUpdate();
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXPRINTLib' for the library: 'ExPrint 1.0 Control Library'

	#import <ExPrint.dll>
	using namespace EXPRINTLib;
*/
EXPRINTLib::IExPrintPtr var_Print = ::CreateObject(L"Exontrol.Print");
	var_Print->PutOptions("FitToPage = On");
	var_Print->PutPrintExt(((EXTREELib::ITreePtr)(spTree1)));
	var_Print->Preview();

565
Does your control supports scrolling by touching the screen

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->PutAutoDrag(EXTREELib::AutoDragEnum(EXTREELib::exAutoDragScrollOnShortTouch | EXTREELib::exAutoDragScroll));
spTree1->PutScrollBySingleLine(VARIANT_TRUE);
spTree1->PutContinueColumnScroll(VARIANT_TRUE);
spTree1->EndUpdate();

564
How do I prevent showing the control's BackColorAlternate property on empty / non-items part of the control

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutBackColorAlternate(0x7ff0f0f0);
spTree1->GetColumns()->Add(L"Column");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
	var_Items->AddItem("Item 4");
	var_Items->AddItem("Item 5");

563
Is there a syntax for conditional formatting of items, based on CellState/CellStateChange

// CellStateChanged event - Fired after cell's state has been changed.
void OnCellStateChangedTree1(long   Item,long   ColIndex)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		var_Items->PutCellCaption(Item,long(2),var_Items->GetCellState(Item,long(0)));
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutSelBackMode(EXTREELib::exTransparent);
EXTREELib::IConditionalFormatPtr var_ConditionalFormat = spTree1->GetConditionalFormats()->Add(L"%2 != 0",vtMissing);
	var_ConditionalFormat->PutBold(VARIANT_TRUE);
	var_ConditionalFormat->PutForeColor(RGB(255,0,0));
	var_ConditionalFormat->PutApplyTo(EXTREELib::exFormatToItems);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"")));
	var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column->PutWidth(16);
	var_Column->PutAllowSizing(VARIANT_FALSE);
spTree1->GetColumns()->Add(L"Information");
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Hidden")))->PutVisible(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem(""),long(1),"This is a bit of text associated");
	long h = var_Items->AddItem("");
	var_Items->PutCellCaption(h,long(1),"This is a bit of text associated");
	var_Items->PutCellState(h,long(0),1);
	var_Items->PutCellCaption(var_Items->AddItem(""),long(1),"This is a bit of text associated");
spTree1->EndUpdate();

562
How can I start editing the cell as soon as the user clicks a cell

// AfterCellEdit event - Occurs after data in the current cell is edited.
void OnAfterCellEditTree1(long   Item,long   ColIndex,LPCTSTR   NewCaption)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	spTree1->GetItems()->PutCellCaption(Item,ColIndex,NewCaption);
}

// CancelCellEdit event - Occurs if the edit operation is canceled.
void OnCancelCellEditTree1(long   Item,long   ColIndex,VARIANT   Reserved)
{
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	spTree1->GetItems()->PutCellCaption(Item,ColIndex,Reserved);
}

// Click event - Occurs when the user presses and then releases the left mouse button over the tree control.
void OnClickTree1()
{
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		var_Items->Edit(var_Items->GetFocusItem(),long(0));
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutAllowEdit(VARIANT_TRUE);
spTree1->GetColumns()->Add(L"Column");
spTree1->GetItems()->AddItem("Item 1");
spTree1->GetItems()->AddItem("Item 2");
spTree1->GetItems()->AddItem("");

561
How do I programmatically exclude items from the filter

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Items")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowExclude | EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
	var_Items->AddItem("Item 4");
EXTREELib::IColumnPtr var_Column1 = spTree1->GetColumns()->GetItem(long(0));
	var_Column1->PutFilterType(EXTREELib::FilterTypeEnum(EXTREELib::exFilterExclude | EXTREELib::exFilter));
	var_Column1->PutFilter(L"Item 1|Item 4");
spTree1->ApplyFilter();
spTree1->EndUpdate();

560
How can I sort the columns to be displayed on the columns floating bar

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"City")))->PutVisible(VARIANT_FALSE);
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Start")))->PutVisible(VARIANT_FALSE);
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"End")))->PutVisible(VARIANT_FALSE);
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);
spTree1->PutColumnsFloatBarSortOrder(EXTREELib::SortAscending);

559
How can I add a vertical padding

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutDrawGridLines(EXTREELib::exAllLines);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Padding")));
	var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column->PutDef(EXTREELib::exCellSingleLine,VARIANT_FALSE);
	var_Column->PutDef(EXTREELib::exCellPaddingLeft,long(6));
	var_Column->PutDef(EXTREELib::exCellPaddingRight,long(6));
	var_Column->PutDef(EXTREELib::exCellPaddingTop,long(6));
	var_Column->PutDef(EXTREELib::exCellPaddingBottom,long(6));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("padding");
	var_Items->AddItem("padding");
spTree1->EndUpdate();

558
Is the PutItems method running .AddItem event

// AddItem event - Occurs after a new Item has been inserted to Items collection.
void OnAddItemTree1(long   Item)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	OutputDebugStringW( L"Adding ..." );
	OutputDebugStringW( _bstr_t(spTree1->GetItems()->GetCellCaption(Item,long(0))) );
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->GetColumns()->Add(L"Def");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
OutputDebugStringW( L"Call PutItems" );
spTree1->PutItems(spTree1->GetItems(long(-1)),vtMissing);

557
How do you embed HTML options into the anchor click string

// AnchorClick event - Occurs when an anchor element is clicked.
void OnAnchorClickTree1(LPCTSTR   AnchorID,LPCTSTR   Options)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	OutputDebugStringW( L"AnchorID" );
	OutputDebugStringW( L"Options" );
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Car")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("<a mazda_1;options for 1>Mazda <b>1</b></a>");
	var_Items->AddItem("<a mazda_2;options for 2>Mazda <b>2</b></a>");
	var_Items->AddItem("<a mazda_3;options for 3a>Mazda <b>3.a</b></a>");
	var_Items->AddItem("<a mazda_3;options for 3b>Mazda <b>3.b</b></a>");
spTree1->EndUpdate();

556
I have the rows with different background color, and when I select the item it takes the color of the SelBackColor, and therefore is no longer visible behind the color. Is there any option to make the item's color being visible (method 3)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetVisualAppearance()->Add(1,_bstr_t("gBFLBCJwBAEHhEJAEGg4BVEIQAAYAQGKIYBkAKBQAGaAoDDMOQwQwAAxjGKEEwsACEIrjKCRShyCYZRhGcTSBCIZBqEqSZLiEZRQCWIAzATGYBRfIUEgjBM6ExwG78e") +
"gBHp/ZpkACIJJAaRjHQdJxGKKMQB9DIhCZpeKhWgkKIJBzOEyBRC4ERBGqNGrsIgLEqWZpnWhaNpWXYTLyBN64LhuK46g53O6wLxvK6hEr2dJ/YBcIAOfghf4NQ7EMRx" +
"LC8Mw3BDvYDkOAABAIgI=");
spTree1->PutSelBackColor(0x1fffffe);
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->GetColumns()->Add(L"Items");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutItemBackColor(var_Items->AddItem("red"),RGB(255,0,0));
	var_Items->PutItemBackColor(var_Items->AddItem("blue"),RGB(0,0,255));
	var_Items->PutItemBackColor(var_Items->AddItem("green"),RGB(0,255,0));
spTree1->EndUpdate();

555
I have the rows with different background color, and when I select the item it takes the color of the SelBackColor, and therefore is no longer visible behind the color. Is there any option to make the item's color being visible (method 2)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutSelBackMode(EXTREELib::exTransparent);
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->GetColumns()->Add(L"Items");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutItemBackColor(var_Items->AddItem("red"),RGB(255,0,0));
	var_Items->PutItemBackColor(var_Items->AddItem("blue"),RGB(0,0,255));
	var_Items->PutItemBackColor(var_Items->AddItem("green"),RGB(0,255,0));
spTree1->EndUpdate();

554
I have the rows with different background color, and when I select the item it takes the color of the SelBackColor, and therefore is no longer visible behind the color. Is there any option to make the item's color being visible (method 1)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutSelBackColor(spTree1->GetBackColor());
spTree1->PutSelForeColor(spTree1->GetForeColor());
spTree1->PutShowFocusRect(VARIANT_TRUE);
spTree1->GetColumns()->Add(L"Items");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutItemBackColor(var_Items->AddItem("red"),RGB(255,0,0));
	var_Items->PutItemBackColor(var_Items->AddItem("blue"),RGB(0,0,255));
	var_Items->PutItemBackColor(var_Items->AddItem("green"),RGB(0,255,0));
spTree1->EndUpdate();

553
How do I arrange my columns on multiple levels

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutDrawGridLines(EXTREELib::exAllLines);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"C0")));
		var_Column->PutExpandColumns(L"1,2");
		var_Column->PutDisplayExpandButton(VARIANT_FALSE);
	var_Columns->Add(L"C1");
	var_Columns->Add(L"C2");
	var_Columns->Add(L"C3");
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"C4")));
		var_Column1->PutExpandColumns(L"5,6");
		var_Column1->PutDisplayExpandButton(VARIANT_FALSE);
	var_Columns->Add(L"C5");
	EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"C6")));
		var_Column2->PutExpandColumns(L"6,7");
		var_Column2->PutDisplayExpandButton(VARIANT_FALSE);
	var_Columns->Add(L"C7");
spTree1->EndUpdate();

552
Does your control support expandable header or columns, so I can arrange it on multiple levels

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutDrawGridLines(EXTREELib::exAllLines);
spTree1->PutBackColorLevelHeader(RGB(240,240,240));
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Photo")));
		var_Column->PutAllowSizing(VARIANT_FALSE);
		var_Column->PutWidth(32);
	var_Columns->Add(L"Personal Info");
	var_Columns->Add(L"Title");
	var_Columns->Add(L"Name");
	var_Columns->Add(L"First");
	var_Columns->Add(L"Last");
	var_Columns->Add(L"Address");
	var_Columns->GetItem("Personal Info")->PutExpandColumns(L"2,3");
	EXTREELib::IColumnPtr var_Column1 = var_Columns->GetItem("Name");
		var_Column1->PutExpandColumns(L"4,5");
		var_Column1->PutExpanded(VARIANT_FALSE);
spTree1->EndUpdate();

551
Does your control support subscript or superscript, in HTML captions

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutHeaderHeight(28);
spTree1->PutDefaultItemHeight(24);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 1")));
		var_Column->PutHTMLCaption(L"Column <b><off 2><font ;6>1");
		var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")));
		var_Column1->PutHTMLCaption(L"Column <b><off 2><font ;6>2");
		var_Column1->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 3")));
		var_Column2->PutHTMLCaption(L"Column <b><off 2><font ;6>3");
		var_Column2->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Item <font ;6><off 4>1");
	var_Items->PutCellCaption(h,long(1),"Item <font ;6><off -6>2");
	var_Items->PutCellCaption(h,long(2),"Item <b><font ;6><off -6>2<off 4>3<off 4>1");

550
Is there any property I can save and restore automatically the current setting, column position, size, and so on (2)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetColumns()->Add(L"Column");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
spTree1->PutLayout(L"Select=\"0\";SingleSort=\"C0:2\";Columns=1");
spTree1->EndUpdate();

549
Is there any property I can save and restore automatically the current setting, column position, size, and so on (1)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetColumns()->Add(L"Column");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->AddItem("Item 2");
	var_Items->AddItem("Item 3");
spTree1->PutLayout(_bstr_t("gBjAAwAAuABmABpABsAB0ABlAByhoAPIAOEPAA9gYABoABQAgUEg0XN4AOcJicKkpujMbjsfkMFk0YhkQgUOjUEl8gjcGO0ok8KMULjEaGMcj08kQAO8oMkTNEtGwAG") +
"QAqc7gUlhh1ABtAEsk9GpEfhElgVcsMupNlnlonlaAFcr0shUsp8QPEtnVJqJhmcIhUMh0QiU5sYAqMngUSuEMw07k8Qv0SgVRrNEuVflF2jF5x9JyNEm0TjQijemyE0" +
"jE3t+YruauoAu4Az1qj9BzRn0UzksSnAA0xDjY6qnAw8OiUQ0dwzN0zWz2t7j8/xURAGNvWH6k8xlEhklhEI0O/6QAgI=");
spTree1->EndUpdate();

548
I have noticed that the column's header is changed once the cursor hovers it. Is it possible to change that visual appearance

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->GetVisualAppearance()->Add(1,"c:\\exontrol\\images\\normal.ebn");
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	var_Columns->Add(L"Column 2");
spTree1->PutBackColorHeader(0x1000000);
spTree1->PutBackground(EXTREELib::exCursorHoverColumn,0x12d86ff);

547
Is it possible to change the visual appearance of the columns selector/floating bar(3)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
spTree1->GetVisualAppearance()->Add(2,"c:\\exontrol\\images\\normal.ebn");
spTree1->GetVisualAppearance()->Add(3,"c:\\exontrol\\images\\pushed.ebn");
spTree1->PutBackground(EXTREELib::exColumnsFloatAppearance,0x2000000);
spTree1->PutBackground(EXTREELib::exColumnsFloatBackColor,0x3000000);
spTree1->PutBackground(EXTREELib::exColumnsFloatCaptionBackColor,RGB(246,245,240));
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

546
Is it possible to change the visual appearance of the columns selector/floating bar(2)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
spTree1->GetVisualAppearance()->Add(3,"c:\\exontrol\\images\\pushed.ebn");
spTree1->PutBackground(EXTREELib::exColumnsFloatBackColor,0x3000000);
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

545
Is it possible to change the visual appearance of the columns selector/floating bar(1)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->GetVisualAppearance()->Add(2,"c:\\exontrol\\images\\normal.ebn");
spTree1->PutBackground(EXTREELib::exColumnsFloatAppearance,0x2000000);
spTree1->PutBackground(EXTREELib::exColumnsFloatBackColor,RGB(246,245,240));
spTree1->PutBackground(EXTREELib::exColumnsFloatCaptionBackColor,RGB(246,245,240));
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

544
I am using the ColumnsFloatBarVisible property on True, but still not able to add any column on that list

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

543
Is it possible to list a column to columns selector/floating bar, but still user can use it

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 3")));
		var_Column->PutVisible(VARIANT_FALSE);
		var_Column->PutEnabled(VARIANT_FALSE);
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

542
How can I prevent a specific column not to be listed in the columns selector/floating bar

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 3")));
		var_Column->PutVisible(VARIANT_FALSE);
		var_Column->PutAllowDragging(VARIANT_FALSE);
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

541
Is it possible to change the "Columns" caption being shown in the columns selector/floating bar

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
spTree1->PutDescription(EXTREELib::exColumnsFloatBar,L"Hidden Columns");
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

540
How can I show the columns selector, so the user can drag and drop columns to the view

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"Column 2")))->PutVisible(VARIANT_FALSE);
spTree1->PutColumnsFloatBarVisible(EXTREELib::exColumnsFloatBarVisibleIncludeHiddenColumns);

539
The column's header is changed while the cursor hovers it. Is it possible to prevent that

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Column 1");
	var_Columns->Add(L"Column 2");
spTree1->PutBackground(EXTREELib::exCursorHoverColumn,-1);

538
Is there any public method to export the selected data

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"C1");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"C2")))->PutFormatColumn(L"1 index `A-Z`");
	((EXTREELib::IColumnPtr)(var_Columns->Add(L"C3")))->PutFormatColumn(L"100 index ``");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Item 1");
	var_Items->PutSelectItem(var_Items->AddItem("Item 2"),VARIANT_TRUE);
	var_Items->AddItem("Item 3");
spTree1->EndUpdate();
OutputDebugStringW( L"Export CSV Selected Items Only:" );
OutputDebugStringW( _bstr_t(spTree1->Export("","sel")) );

537
Is it possible to auto-numbering the children items but still keeps the position after filtering

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Items")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutFilterType(EXTREELib::exFilter);
	var_Column->PutFilter(L"Child 2");
EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.1")));
	var_Column1->PutFormatColumn(L"1 ropos ''");
	var_Column1->PutPosition(0);
	var_Column1->PutWidth(32);
	var_Column1->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.2")));
	var_Column2->PutFormatColumn(L"1 ropos ':'");
	var_Column2->PutPosition(1);
	var_Column2->PutWidth(32);
	var_Column2->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column3 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.3")));
	var_Column3->PutFormatColumn(L"1 ropos ':|A-Z'");
	var_Column3->PutPosition(2);
	var_Column3->PutWidth(32);
	var_Column3->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column4 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.4")));
	var_Column4->PutFormatColumn(L"1 ropos '|A-Z|'");
	var_Column4->PutPosition(3);
	var_Column4->PutWidth(32);
	var_Column4->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column5 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.5")));
	var_Column5->PutFormatColumn(L"'<font Tahoma;7>' + 1 ropos '-<b>||A-Z'");
	var_Column5->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	var_Column5->PutPosition(4);
	var_Column5->PutWidth(32);
	var_Column5->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column6 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.6")));
	var_Column6->PutFormatColumn(L"'<b>'+ 1 ropos '</b>:<fgcolor=FF0000>|A-Z|'");
	var_Column6->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	var_Column6->PutPosition(5);
	var_Column6->PutWidth(48);
	var_Column6->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root 1");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("Root 2");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
spTree1->ApplyFilter();
spTree1->EndUpdate();

536
Is it possible to auto-numbering the children items too

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->GetColumns()->Add(L"Items");
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.1")));
	var_Column->PutFormatColumn(L"1 rpos ''");
	var_Column->PutPosition(0);
	var_Column->PutWidth(32);
	var_Column->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.2")));
	var_Column1->PutFormatColumn(L"1 rpos ':'");
	var_Column1->PutPosition(1);
	var_Column1->PutWidth(32);
	var_Column1->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.3")));
	var_Column2->PutFormatColumn(L"1 rpos ':|A-Z'");
	var_Column2->PutPosition(2);
	var_Column2->PutWidth(32);
	var_Column2->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column3 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.4")));
	var_Column3->PutFormatColumn(L"1 rpos '|A-Z|'");
	var_Column3->PutPosition(3);
	var_Column3->PutWidth(32);
	var_Column3->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column4 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.5")));
	var_Column4->PutFormatColumn(L"'<font Tahoma;7>' + 1 rpos '-<b>||A-Z'");
	var_Column4->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	var_Column4->PutPosition(4);
	var_Column4->PutWidth(32);
	var_Column4->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IColumnPtr var_Column5 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Pos.6")));
	var_Column5->PutFormatColumn(L"'<b>'+ 1 rpos '</b>:<fgcolor=FF0000>|A-Z|'");
	var_Column5->PutDef(EXTREELib::exCellCaptionFormat,long(1));
	var_Column5->PutPosition(5);
	var_Column5->PutWidth(48);
	var_Column5->PutAllowSizing(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root 1");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("Root 2");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
spTree1->EndUpdate();

535
How can I find if there is any filter applied to the control

// FilterChange event - Notifies your application that the filter is changed.
void OnFilterChangeTree1()
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	OutputDebugStringW( L"If negative, the filter is present, else not" );
	OutputDebugStringW( _bstr_t(spTree1->GetItems()->GetVisibleItemCount()) );
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutTreeColumnIndex(-1);
spTree1->PutFilterInclude(EXTREELib::exMatchingItemsOnly);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Column")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutFilterType(EXTREELib::exFilter);
	var_Column->PutFilter(L"C1");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("R1");
	var_Items->InsertItem(h,vtMissing,"C1");
	var_Items->InsertItem(h,vtMissing,"C2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("R2");
	var_Items->InsertItem(h,vtMissing,"C1");
	var_Items->InsertItem(h,vtMissing,"C2");
spTree1->ApplyFilter();
spTree1->EndUpdate();

534
How can I prevent showing the lines for the hierarchy while using the exMatchingItemsOnly option

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutTreeColumnIndex(-1);
spTree1->PutFilterInclude(EXTREELib::exMatchingItemsOnly);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Column")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutFilterType(EXTREELib::exFilter);
	var_Column->PutFilter(L"C1|C2");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("R1");
	var_Items->InsertItem(h,vtMissing,"C1");
	var_Items->InsertItem(h,vtMissing,"C2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("R2");
	var_Items->InsertItem(h,vtMissing,"C1");
	var_Items->InsertItem(h,vtMissing,"C2");
spTree1->ApplyFilter();
spTree1->EndUpdate();

533
Is there any method to get only the matched items and not the items with his parent

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->PutFilterInclude(EXTREELib::exMatchingItemsOnly);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Column")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutFilterType(EXTREELib::exFilter);
	var_Column->PutFilter(L"C1|C2");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("R1");
	var_Items->InsertItem(h,vtMissing,"C1");
	var_Items->InsertItem(h,vtMissing,"C2");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("R2");
	var_Items->InsertItem(h,vtMissing,"C1");
	var_Items->InsertItem(h,vtMissing,"C2");
spTree1->ApplyFilter();
spTree1->EndUpdate();

532
How can I add or change the padding (spaces) for captions in the control's header

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Padding-Left")))->PutDef(EXTREELib::exHeaderPaddingLeft,long(18));
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Padding-Right")));
	var_Column->PutDef(EXTREELib::exHeaderPaddingRight,long(18));
	var_Column->PutHeaderAlignment(EXTREELib::RightAlignment);
spTree1->EndUpdate();

531
Do you have any plans to add cell spacing and cell padding to the cells

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutDrawGridLines(EXTREELib::exRowLines);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Padding-Left")));
	var_Column->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
	var_Column->PutDef(EXTREELib::exCellPaddingLeft,long(18));
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"No-Padding")))->PutDef(EXTREELib::exCellHasCheckBox,VARIANT_TRUE);
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Empty")))->PutPosition(0);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem("Item A.1"),long(1),"Item A.2");
	var_Items->PutCellCaption(var_Items->AddItem("Item B.1"),long(1),"Item B.2");
	var_Items->PutCellCaption(var_Items->AddItem("Item C.1"),long(1),"Item C.2");
spTree1->EndUpdate();

530
Is it possible display numbers in the same format no matter of regional settings in the control panel

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default positive)'");
	h = var_Items->AddItem(double(100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '2|.|3|,|1|1')");
	h = var_Items->AddItem(double(-100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default negative)'");
	h = var_Items->AddItem(double(-100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '2|.|3|,|1|1')");
spTree1->EndUpdate();

529
Is it possible to add a 0 for numbers less than 1 instead .7 to show 0.8

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(0.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default)'");
	h = var_Items->AddItem(double(0.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '|||||0') +  ' <fgcolor=808080>(Display no leading zeros)'");
spTree1->EndUpdate();

528
How can I specify the format for negative numbers

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(-100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default)'");
	h = var_Items->AddItem(double(-100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '||||1') +  ' <fgcolor=808080>(Negative sign, number; for example, -1.1)'");
spTree1->EndUpdate();

527
Is it possible to change the grouping character when display numbers

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default)'");
	h = var_Items->AddItem(double(100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '|||-') +  ' <fgcolor=808080>(grouping character is -)'");
spTree1->EndUpdate();

526
How can I display numbers with 2 digits in each group

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default)'");
	h = var_Items->AddItem(double(100000.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '||2') +  ' <fgcolor=808080>(grouping by 2 digits)'");
spTree1->EndUpdate();

525
How can I display my numbers using a different decimal separator

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(100.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default)'");
	h = var_Items->AddItem(double(100.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '|;') +  ' <fgcolor=808080>(decimal separator is <b>;</b>)'");
spTree1->EndUpdate();

524
Is it possible to display the numbers using 3 (three) digits

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Def")))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem(double(100.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '') +  ' <fgcolor=808080>(default)'");
	h = var_Items->AddItem(double(100.27));
	var_Items->PutFormatCell(h,long(0),L"(value format '3') +  ' <fgcolor=808080>(3 digits)'");
	h = var_Items->AddItem(double(100.27));
	var_Items->PutFormatCell(h,long(0),L"(value format 2) +  '  <fgcolor=808080>(2 digits)'");
	h = var_Items->AddItem(double(100.27));
	var_Items->PutFormatCell(h,long(0),L"(value format 1) +  ' <fgcolor=808080>(1 digit)'");
spTree1->EndUpdate();

523
Is it possible to format numbers

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Name");
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"A")));
		var_Column->PutSortType(EXTREELib::SortNumeric);
		var_Column->PutAllowSizing(VARIANT_FALSE);
		var_Column->PutWidth(36);
		var_Column->PutFormatColumn(L"len(value) ? value + ' +'");
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"B")));
		var_Column1->PutSortType(EXTREELib::SortNumeric);
		var_Column1->PutAllowSizing(VARIANT_FALSE);
		var_Column1->PutWidth(36);
		var_Column1->PutFormatColumn(L"len(value) ? value + ' +'");
	EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"C")));
		var_Column2->PutSortType(EXTREELib::SortNumeric);
		var_Column2->PutAllowSizing(VARIANT_FALSE);
		var_Column2->PutWidth(36);
		var_Column2->PutFormatColumn(L"len(value) ? value + ' ='");
	EXTREELib::IColumnPtr var_Column3 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"A+B+C")));
		var_Column3->PutSortType(EXTREELib::SortNumeric);
		var_Column3->PutWidth(64);
		var_Column3->PutComputedField(L"dbl(%1)+dbl(%2)+dbl(%3)");
		var_Column3->PutFormatColumn(_bstr_t("type(value) in (0,1) ? 'null' : ( dbl(value)<0 ? '<fgcolor=FF0000>'+ (value format '2|.|3|,|1' ) : (dbl(value)>0 ? '<fgcolor=00") +
"00FF>+'+(value format '2|.|3|,' ): '0.00') )");
		var_Column3->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root");
	var_Items->PutCellCaptionFormat(h,long(4),EXTREELib::exComputedField);
	long h1 = var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->PutCellCaption(h1,long(1),long(7));
	var_Items->PutCellCaption(h1,long(2),long(3));
	var_Items->PutCellCaption(h1,long(3),long(1));
	h1 = var_Items->InsertItem(h,vtMissing,"Child 2");
	var_Items->PutCellCaption(h1,long(1),long(-2));
	var_Items->PutCellCaption(h1,long(2),long(-2));
	var_Items->PutCellCaption(h1,long(3),long(-4));
	h1 = var_Items->InsertItem(h,vtMissing,"Child 3");
	var_Items->PutCellCaption(h1,long(1),long(2));
	var_Items->PutCellCaption(h1,long(2),long(2));
	var_Items->PutCellCaption(h1,long(3),long(-4));
	var_Items->PutExpandItem(h,VARIANT_TRUE);
spTree1->EndUpdate();

522
I am using the FormatColumn/FormatCell to format my columns. Is it possible to ignore the SelForeColor, so the foreground color for selected items does not override my settings

// SelectionChanged event - Fired after a new item has been selected.
void OnSelectionChangedTree1()
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		var_Items->ClearItemBackColor(0);
		var_Items->PutItemBackColor(var_Items->GetSelectedItem(0),RGB(128,255,255));
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutSelForeColor(spTree1->GetForeColor());
spTree1->PutSelBackColor(spTree1->GetBackColor());
spTree1->PutShowFocusRect(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Format")));
		var_Column->PutFormatColumn(_bstr_t("type(value) in (0,1) ? 'null' : ( dbl(value)<0 ? '<fgcolor=FF0000>'+ (value format '2|.|3|,|1' ) : (dbl(value)>0 ? '<fgcolor=00") +
"00FF>+'+(value format '2|.|3|,' ): '0.00') )");
		var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem(long(10));
	var_Items->AddItem(long(-8));
spTree1->EndUpdate();

521
Is it possible to change the height for all items at once

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
spTree1->GetColumns()->Add(L"Items");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root 1");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
	h = var_Items->AddItem("Root 2");
	var_Items->InsertItem(h,vtMissing,"Child 1");
	var_Items->InsertItem(h,vtMissing,"Child 2");
	var_Items->PutExpandItem(0,VARIANT_TRUE);
spTree1->EndUpdate();
spTree1->PutDefaultItemHeight(12);
spTree1->GetItems()->PutItemHeight(0,12);

520
How can I add a footer row

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutShowLockedItems(VARIANT_TRUE);
spTree1->PutDrawGridLines(EXTREELib::exVLines);
spTree1->GetColumns()->Add(L"C1");
spTree1->GetColumns()->Add(L"C2");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutLockedItemCount(EXTREELib::BottomAlignment,1);
	long h = var_Items->GetLockedItem(EXTREELib::BottomAlignment,0);
	var_Items->PutItemBackColor(h,RGB(128,128,128));
	var_Items->PutItemForeColor(h,RGB(255,255,255));
	var_Items->PutCellCaption(h,long(0),"footer c1");
	var_Items->PutCellCaption(h,long(1),"footer c2");
	var_Items->PutCellCaption(var_Items->AddItem("cell"),long(1),"cell");

519
How can I add a header row

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutShowLockedItems(VARIANT_TRUE);
spTree1->PutDrawGridLines(EXTREELib::exVLines);
spTree1->GetColumns()->Add(L"C1");
spTree1->GetColumns()->Add(L"C2");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutLockedItemCount(EXTREELib::TopAlignment,1);
	long h = var_Items->GetLockedItem(EXTREELib::TopAlignment,0);
	var_Items->PutItemBackColor(h,RGB(128,128,128));
	var_Items->PutItemForeColor(h,RGB(255,255,255));
	var_Items->PutCellCaption(h,long(0),"footer c1");
	var_Items->PutCellCaption(h,long(1),"footer c2");
	var_Items->PutCellCaption(var_Items->AddItem("cell"),long(1),"cell");

518
When I'm trying to show string with "line break" character (vbCrLF) in a textbox, it shows 2 squares. Is there any way to hide these squares

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Value");
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"CellSingleLine = False")));
		var_Column->PutComputedField(L"%0");
		var_Column->PutDef(EXTREELib::exCellSingleLine,VARIANT_FALSE);
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"FormatColumn/replace CRLF")));
		var_Column1->PutComputedField(L"%0");
		var_Column1->PutFormatColumn(L"value replace `\\r\\n` with ``");
	EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"FormatColumn/replace TAB,CRLF")));
		var_Column2->PutComputedField(L"%0");
		var_Column2->PutFormatColumn(L"(value replace `\\t` with ``) replace `\\r\\n` with ``");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("a\\ta\\r\\nb\\tb");

517
Is there any way to "unselect" radio group

// DblClick event - Occurs when the user dblclk the left mouse button over an object.
void OnDblClickTree1(short   Shift,long   X,long   Y)
{
	/*
		Copy and paste the following directives to your header file as
		it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'
		#import <ExTree.dll>
		using namespace EXTREELib;
	*/
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		long h = var_Items->GetCellChecked(1234);
		var_Items->PutCellHasCheckBox(long(0),h,VARIANT_TRUE);
		var_Items->PutCellState(long(0),h,0);
		var_Items->PutCellHasCheckBox(long(0),h,VARIANT_FALSE);
}

// SelectionChanged event - Fired after a new item has been selected.
void OnSelectionChangedTree1()
{
	EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
	EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
		var_Items->PutCellState(var_Items->GetFocusItem(),long(0),1);
}

EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutSelBackColor(RGB(255,255,128));
spTree1->PutSelForeColor(RGB(0,0,0));
spTree1->GetColumns()->Add(L"Default");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Radio 1");
	var_Items->PutCellHasRadioButton(h,long(0),VARIANT_TRUE);
	var_Items->PutCellRadioGroup(h,long(0),1234);
	h = var_Items->AddItem("Radio 2");
	var_Items->PutCellHasRadioButton(h,long(0),VARIANT_TRUE);
	var_Items->PutCellRadioGroup(h,long(0),1234);
	var_Items->PutCellState(h,long(0),1);
	h = var_Items->AddItem("Radio 3");
	var_Items->PutCellHasRadioButton(h,long(0),VARIANT_TRUE);
	var_Items->PutCellRadioGroup(h,long(0),1234);

516
The Column.Alignment property does not seem to work for cells with images in them. What can be done

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->Images(_bstr_t("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq") +
"lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" +
"0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" +
"NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=");
spTree1->PutTreeColumnIndex(-1);
spTree1->PutDrawGridLines(EXTREELib::exAllLines);
spTree1->PutHeaderHeight(24);
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
spTree1->PutDefaultItemHeight(24);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Image")));
	var_Column->PutAllowSizing(VARIANT_FALSE);
	var_Column->PutWidth(32);
	var_Column->PutHTMLCaption(L"<img>1</img>");
	var_Column->PutHeaderAlignment(EXTREELib::CenterAlignment);
	var_Column->PutAlignment(EXTREELib::CenterAlignment);
	var_Column->PutDef(EXTREELib::exCellCaptionFormat,long(1));
spTree1->GetColumns()->Add(L"Rest");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("<img>1</img>");
	var_Items->AddItem("<img>2</img>");
	var_Items->AddItem("<img>3</img>");
spTree1->EndUpdate();

515
Can I change the format of date to be shown in the control

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	var_Columns->Add(L"Default");
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Format.1")));
		var_Column->PutComputedField(L"%0");
		var_Column->PutFormatColumn(L"dateF(value) replace `/` with `-`");
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Format.2")));
		var_Column1->PutComputedField(L"%0");
		var_Column1->PutDef(EXTREELib::exCellCaptionFormat,long(1));
		var_Column1->PutFormatColumn(L"`<b>`+ shortdate(value) + `</b> ` + timeF(value)");
	EXTREELib::IColumnPtr var_Column2 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Format.3")));
		var_Column2->PutComputedField(L"%0");
		var_Column2->PutDef(EXTREELib::exCellCaptionFormat,long(1));
		var_Column2->PutFormatColumn(_bstr_t("( dateF(value) replace `/` with `-` ) + ` <b>`+ ( weekday(value) case ( 0 : `Su`; 1 : `Mo`; 2 : `Tu`; 3 : `We`; 4 : `Th`; 5 : `") +
"Fr`; 6 : `Sa`) )");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem(COleDateTime(2001,1,1,10,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2001,1,2,10,00,00).operator DATE());

514
Is it possible to scroll the control's content by clicking and dragging

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->PutAutoDrag(EXTREELib::exAutoDragScroll);
spTree1->EndUpdate();

513
How can copy and paste the selection to Microsoft Word, any OLE compliant application, as a snapshot
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetVisualAppearance()->Add(1,"c:\\exontrol\\images\\normal.ebn");
spTree1->PutHTMLPicture(L"p1","c:\\exontrol\\images\\card.png");
spTree1->PutHTMLPicture(L"p2","c:\\exontrol\\images\\sun.png");
spTree1->PutAutoDrag(EXTREELib::exAutoDragCopySnapShot);
spTree1->PutLinesAtRoot(EXTREELib::exNoLinesAtRoot);
spTree1->PutHasLines(EXTREELib::exThinLine);
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->PutDefaultItemHeight(26);
spTree1->GetColumns()->Add(L"Task");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("<img>p1:32</img>Group 1");
	var_Items->PutCellCaptionFormat(h,long(0),EXTREELib::exHTML);
	var_Items->PutItemDivider(h,0);
	var_Items->PutItemBold(h,VARIANT_TRUE);
	long h1 = var_Items->InsertItem(h,vtMissing,"Task 1");
	long h2 = var_Items->InsertItem(h,vtMissing,"Task 2");
	long h3 = var_Items->InsertItem(h,vtMissing,"Task 3");
	h = var_Items->AddItem("<img>p2:32</img>Group 2");
	var_Items->PutCellCaptionFormat(h,long(0),EXTREELib::exHTML);
	var_Items->PutItemBold(h,VARIANT_TRUE);
	var_Items->PutItemDivider(h,0);
	h1 = var_Items->InsertItem(h,vtMissing,"Task");
	var_Items->PutExpandItem(0,VARIANT_TRUE);
spTree1->EndUpdate();

512
How can copy and paste the selection to Microsoft Word, any OLE compliant application, as a image

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutHTMLPicture(L"p1","c:\\exontrol\\images\\card.png");
spTree1->PutHTMLPicture(L"p2","c:\\exontrol\\images\\sun.png");
_variant_t var_HTMLPicture = spTree1->GetHTMLPicture(L"aka1");
spTree1->PutHeaderHeight(24);
spTree1->PutDefaultItemHeight(48);
spTree1->PutDrawGridLines(EXTREELib::exRowLines);
spTree1->PutGridLineColor(RGB(240,240,240));
spTree1->PutSelBackMode(EXTREELib::exTransparent);
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->GetColumns()->GetItem(long(0))->PutDef(EXTREELib::exCellCaptionFormat,long(1));
spTree1->GetColumns()->GetItem(long(0))->PutFormatColumn(L"value + ` <img>p` + (1 + (value mod 3 ) ) + `</img>`");
spTree1->GetColumns()->GetItem(long(0))->PutWidth(112);
spTree1->GetColumns()->GetItem(long(1))->PutDef(EXTREELib::exCellHasCheckBox,long(1));
spTree1->GetColumns()->GetItem(long(2))->PutLevelKey("1");
spTree1->GetColumns()->GetItem(long(3))->PutLevelKey("1");
spTree1->GetColumns()->GetItem(long(4))->PutLevelKey("1");
spTree1->PutAutoDrag(EXTREELib::exAutoDragCopyImage);
spTree1->PutSingleSel(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->GetItemByIndex(1);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	h = var_Items->GetItemByIndex(2);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	h = var_Items->GetItemByIndex(3);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	var_Items->PutLockedItemCount(EXTREELib::BottomAlignment,1);
	h = var_Items->GetLockedItem(EXTREELib::BottomAlignment,0);
	var_Items->PutCellCaption(h,long(1),"<font ;16>Click the selection and <b>wait to start dragging</b>, and then drop to Microsoft Word, ...");
	var_Items->PutCellSingleLine(h,long(1),EXTREELib::exCaptionWordWrap);
	var_Items->PutCellCaptionFormat(h,long(1),EXTREELib::exHTML);
	var_Items->PutCellHAlignment(h,long(1),EXTREELib::CenterAlignment);
	var_Items->PutItemDivider(h,1);
	var_Items->PutItemDividerLineAlignment(h,EXTREELib::DividerTop);
spTree1->EndUpdate();

511
How can copy and paste the selection to Microsoft Word, Excel or any OLE compliant application, as a text

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutColumnAutoResize(VARIANT_FALSE);
spTree1->PutContinueColumnScroll(VARIANT_FALSE);
/*
	Includes the definition for CreateObject function like follows:

	#include <comdef.h>
	IUnknownPtr CreateObject( BSTR Object )
	{
		IUnknownPtr spResult;
		spResult.CreateInstance( Object );
		return spResult;
	};

*/
/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'ADODB' for the library: 'Microsoft ActiveX Data Objects 6.1 Library'

	#import <msado15.dll> rename("EOF","REOF")
*/
ADODB::_RecordsetPtr rs = ::CreateObject(L"ADOR.Recordset");
	rs->Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\\Program Files\\Exontrol\\ExTree\\Sample\\Access\\sample.mdb",ADODB::adOpenStatic,ADODB::adLockOptimistic,0);
spTree1->PutDataSource(((ADODB::_RecordsetPtr)(rs)));
spTree1->GetColumns()->GetItem(long(2))->PutLevelKey("1");
spTree1->GetColumns()->GetItem(long(3))->PutLevelKey("1");
spTree1->GetColumns()->GetItem(long(4))->PutLevelKey("1");
spTree1->PutAutoDrag(EXTREELib::exAutoDragCopyText);
spTree1->PutSingleSel(VARIANT_FALSE);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->GetItemByIndex(1);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	h = var_Items->GetItemByIndex(3);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	h = var_Items->GetItemByIndex(4);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	h = var_Items->GetItemByIndex(5);
	var_Items->PutSelectItem(h,VARIANT_TRUE);
	var_Items->PutLockedItemCount(EXTREELib::BottomAlignment,1);
	h = var_Items->GetLockedItem(EXTREELib::BottomAlignment,0);
	var_Items->PutCellCaption(h,long(0),"<font ;16>Click the selection and <b>wait to start dragging</b>, and then drop to Microsoft Word, Excel, ...");
	var_Items->PutCellSingleLine(h,long(0),EXTREELib::exCaptionWordWrap);
	var_Items->PutCellCaptionFormat(h,long(0),EXTREELib::exHTML);
	var_Items->PutCellHAlignment(h,long(0),EXTREELib::CenterAlignment);
	var_Items->PutItemDivider(h,0);
	var_Items->PutItemDividerLineAlignment(h,EXTREELib::DividerTop);
spTree1->EndUpdate();

510
Is it possible to change the indentation during the drag and drop

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetVisualAppearance()->Add(1,"c:\\exontrol\\images\\normal.ebn");
spTree1->PutAutoDrag(EXTREELib::exAutoDragPositionAny);
spTree1->PutLinesAtRoot(EXTREELib::exNoLinesAtRoot);
spTree1->PutHasLines(EXTREELib::exSolidLine);
spTree1->PutHasButtons(EXTREELib::exWPlus);
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->PutSelBackMode(EXTREELib::exTransparent);
spTree1->GetColumns()->Add(L"Task");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Group 1");
	var_Items->PutItemBold(h,VARIANT_TRUE);
	var_Items->PutItemDivider(h,0);
	long h1 = var_Items->InsertItem(h,vtMissing,"Task 1");
	long h2 = var_Items->InsertItem(h1,vtMissing,"Task 2");
	h2 = var_Items->InsertItem(h1,vtMissing,"Task 3");
	long h3 = var_Items->InsertItem(h,vtMissing,"Task 3");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	var_Items->PutExpandItem(h1,VARIANT_TRUE);
	h = var_Items->AddItem("Group 2");
	var_Items->PutItemBold(h,VARIANT_TRUE);
	var_Items->PutItemDivider(h,0);
	var_Items->PutLockedItemCount(EXTREELib::BottomAlignment,1);
	h = var_Items->GetLockedItem(EXTREELib::BottomAlignment,0);
	var_Items->PutCellCaption(h,long(0),_bstr_t("Click a row, and move by dragging <b>up, down</b> to change the row's parent or <b>left,right</b> to increase or decrease the i") +
"ndentation.");
	var_Items->PutCellSingleLine(h,long(0),EXTREELib::exCaptionWordWrap);
	var_Items->PutCellCaptionFormat(h,long(0),EXTREELib::exHTML);
spTree1->EndUpdate();

509
Is it possible to allow moving an item to another, but keeping its indentation

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->GetVisualAppearance()->Add(1,"c:\\exontrol\\images\\normal.ebn");
spTree1->PutAutoDrag(EXTREELib::exAutoDragPositionKeepIndent);
spTree1->PutLinesAtRoot(EXTREELib::exNoLinesAtRoot);
spTree1->PutHasLines(EXTREELib::exThinLine);
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->GetColumns()->Add(L"Task");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Group 1");
	var_Items->PutItemDivider(h,0);
	var_Items->PutItemBold(h,VARIANT_TRUE);
	long h1 = var_Items->InsertItem(h,vtMissing,"Task 1");
	long h2 = var_Items->InsertItem(h,vtMissing,"Task 2");
	long h3 = var_Items->InsertItem(h,vtMissing,"Task 3");
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("Group 2");
	var_Items->PutItemBold(h,VARIANT_TRUE);
	var_Items->PutItemDivider(h,0);
spTree1->EndUpdate();

508
How can I change the row's position to another, by drag and drop. Is it possible

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutShowFocusRect(VARIANT_FALSE);
spTree1->GetVisualAppearance()->Add(1,"c:\\exontrol\\images\\normal.ebn");
spTree1->PutAutoDrag(EXTREELib::exAutoDragPosition);
spTree1->GetColumns()->Add(L"Task");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem("Task 1");
	var_Items->AddItem("Task 2");
	var_Items->AddItem("Task 3");
	var_Items->AddItem("Task 4");
spTree1->EndUpdate();

507
How do I enable the scrollbar-extension, as thumb to be shown outside of the control's client area

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutScrollBars(EXTREELib::exDisableBoth);
spTree1->PutScrollPartVisible(EXTREELib::exVScroll,EXTREELib::exExtentThumbPart,VARIANT_TRUE);
spTree1->PutScrollPartVisible(EXTREELib::exHScroll,EXTREELib::exExtentThumbPart,VARIANT_TRUE);
spTree1->PutScrollPartVisible(EXTREELib::ScrollBarEnum(0x2),EXTREELib::exExtentThumbPart,VARIANT_TRUE);
spTree1->PutScrollWidth(4);
spTree1->PutBackground(EXTREELib::exVSBack,RGB(240,240,240));
spTree1->PutBackground(EXTREELib::exVSThumb,RGB(128,128,128));
spTree1->PutScrollHeight(4);
spTree1->PutBackground(EXTREELib::exHSBack,spTree1->GetBackground(EXTREELib::exVSBack));
spTree1->PutBackground(EXTREELib::exHSThumb,spTree1->GetBackground(EXTREELib::exVSThumb));
spTree1->PutBackground(EXTREELib::exScrollSizeGrip,spTree1->GetBackground(EXTREELib::exVSBack));
spTree1->EndUpdate();

506
How can I have a case-insensitive filter (exFilterDoCaseSensitive flag is not set)

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Car")));
		var_Column->PutDisplayFilterButton(VARIANT_TRUE);
		var_Column->PutFilterType(EXTREELib::exFilter);
		var_Column->PutFilter(L"MAZDA");
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Equipment")));
		var_Column1->PutDisplayFilterButton(VARIANT_TRUE);
		var_Column1->PutDisplayFilterPattern(VARIANT_FALSE);
		var_Column1->PutCustomFilter(L"Air Bag||*Air Bag*|||Air condition||*Air condition*|||ABS||*ABS*|||ESP||*ESP*");
		var_Column1->PutFilterType(EXTREELib::exPattern);
		var_Column1->PutFilter(L"AIR BAG");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem("Mazda"),long(1),"Air Bag");
	var_Items->PutCellCaption(var_Items->AddItem("Toyota"),long(1),"Air Bag,Air condition");
	var_Items->PutCellCaption(var_Items->AddItem("Ford"),long(1),"Air condition");
	var_Items->PutCellCaption(var_Items->AddItem("Nissan"),long(1),"Air Bag,ABS,ESP");
	var_Items->PutCellCaption(var_Items->AddItem("Mazda"),long(1),"Air Bag, ABS,ESP");
	var_Items->PutCellCaption(var_Items->AddItem("Mazda"),long(1),"ABS,ESP");
spTree1->ApplyFilter();
spTree1->EndUpdate();

505
How can I have a case-sensitive filter

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutMarkSearchColumn(VARIANT_FALSE);
EXTREELib::IColumnsPtr var_Columns = spTree1->GetColumns();
	EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Car")));
		var_Column->PutDisplayFilterButton(VARIANT_TRUE);
		var_Column->PutFilterType(EXTREELib::FilterTypeEnum(EXTREELib::exFilterDoCaseSensitive | EXTREELib::exFilter));
		var_Column->PutFilter(L"Mazda");
	EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(var_Columns->Add(L"Equipment")));
		var_Column1->PutDisplayFilterButton(VARIANT_TRUE);
		var_Column1->PutDisplayFilterPattern(VARIANT_FALSE);
		var_Column1->PutCustomFilter(L"Air Bag||*Air Bag*|||Air condition||*Air condition*|||ABS||*ABS*|||ESP||*ESP*");
		var_Column1->PutFilterType(EXTREELib::FilterTypeEnum(EXTREELib::exFilterDoCaseSensitive | EXTREELib::exPattern));
		var_Column1->PutFilter(L"Air Bag");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->PutCellCaption(var_Items->AddItem("Mazda"),long(1),"Air Bag");
	var_Items->PutCellCaption(var_Items->AddItem("Toyota"),long(1),"Air Bag,Air condition");
	var_Items->PutCellCaption(var_Items->AddItem("Ford"),long(1),"Air condition");
	var_Items->PutCellCaption(var_Items->AddItem("Nissan"),long(1),"Air Bag,ABS,ESP");
	var_Items->PutCellCaption(var_Items->AddItem("Mazda"),long(1),"Air Bag, ABS,ESP");
	var_Items->PutCellCaption(var_Items->AddItem("Mazda"),long(1),"ABS,ESP");
spTree1->ApplyFilter();
spTree1->EndUpdate();

504
I have several columns, but noticed that the filter is using AND between columns, but I need OR clause for filtering. Is it possible

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
spTree1->PutLinesAtRoot(EXTREELib::exLinesAtRoot);
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Item")));
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column->PutFilter(L"Child 1");
	var_Column->PutFilterType(EXTREELib::exFilter);
EXTREELib::IColumnPtr var_Column1 = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Date")));
	var_Column1->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column1->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column1->PutDisplayFilterDate(VARIANT_TRUE);
	var_Column1->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowExclude | EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox | EXTREELib::exNoItems));
	var_Column1->PutFilter(L"COleDateTime(2010,12,28,0,00,00).operator DATE()");
	var_Column1->PutFilterType(EXTREELib::exDate);
spTree1->PutFilterCriteria(L"%0 or %1");
spTree1->PutDescription(EXTREELib::exFilterBarOr,L"<font ;18><fgcolor=FF0000>or</fgcolor></font>");
spTree1->PutDescription(EXTREELib::exFilterBarAnd,L"<font ;18><fgcolor=FF0000>and</fgcolor></font>");
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	long h = var_Items->AddItem("Root 1");
	var_Items->PutCellCaption(var_Items->InsertItem(h,vtMissing,"Child 1"),long(1),COleDateTime(2010,12,27,0,00,00).operator DATE());
	var_Items->PutCellCaption(var_Items->InsertItem(h,vtMissing,"Child 2"),long(1),COleDateTime(2010,12,28,0,00,00).operator DATE());
	var_Items->PutExpandItem(h,VARIANT_TRUE);
	h = var_Items->AddItem("Root 2");
	var_Items->PutCellCaption(var_Items->InsertItem(h,vtMissing,"Child 1"),long(1),COleDateTime(2010,12,29,0,00,00).operator DATE());
	var_Items->PutCellCaption(var_Items->InsertItem(h,vtMissing,"Child 2"),long(1),COleDateTime(2010,12,30,0,00,00).operator DATE());
spTree1->ApplyFilter();
spTree1->EndUpdate();

503
Is it possible exclude the dates being selected in the drop down filter window

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Date")));
	var_Column->PutSortType(EXTREELib::SortDate);
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column->PutDisplayFilterDate(VARIANT_TRUE);
	var_Column->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowExclude | EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox | EXTREELib::exNoItems));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem(COleDateTime(2010,12,27,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,28,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,29,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,30,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,31,0,00,00).operator DATE());
spTree1->EndUpdate();

502
How can I display a calendar control inside the drop down filter window

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Date")));
	var_Column->PutSortType(EXTREELib::SortDate);
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutDisplayFilterPattern(VARIANT_FALSE);
	var_Column->PutDisplayFilterDate(VARIANT_TRUE);
	var_Column->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox | EXTREELib::exNoItems));
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem(COleDateTime(2010,12,27,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,28,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,29,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,30,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,31,0,00,00).operator DATE());
spTree1->EndUpdate();

501
Is it possible to include the dates as checkb-boxes in the drop down filter window

/*
	Copy and paste the following directives to your header file as
	it defines the namespace 'EXTREELib' for the library: 'ExTree 1.0 Control Library'

	#import <ExTree.dll>
	using namespace EXTREELib;
*/
EXTREELib::ITreePtr spTree1 = GetDlgItem(IDC_TREE1)->GetControlUnknown();
spTree1->BeginUpdate();
EXTREELib::IColumnPtr var_Column = ((EXTREELib::IColumnPtr)(spTree1->GetColumns()->Add(L"Dates")));
	var_Column->PutSortType(EXTREELib::SortDate);
	var_Column->PutDisplayFilterButton(VARIANT_TRUE);
	var_Column->PutDisplayFilterPattern(VARIANT_TRUE);
	var_Column->PutDisplayFilterDate(VARIANT_TRUE);
	var_Column->PutFilterList(EXTREELib::FilterListEnum(EXTREELib::exShowFocusItem | EXTREELib::exShowCheckBox));
	var_Column->PutFilter(L"to 12/27/2010");
	var_Column->PutFilterType(EXTREELib::exDate);
EXTREELib::IItemsPtr var_Items = spTree1->GetItems();
	var_Items->AddItem(COleDateTime(2010,12,27,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,28,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,29,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,30,0,00,00).operator DATE());
	var_Items->AddItem(COleDateTime(2010,12,31,0,00,00).operator DATE());
spTree1->ApplyFilter();
spTree1->EndUpdate();